#include "PController.h"


CPController::CPController()
{
}


CPController::~CPController()
{
}


int CPController::calculate(float input)
{
	///255 - 100
	///x - input
	if (input > 0)
	{
		int output = (this->max * std::abs(input)) / this->maxGas;

		return output;

	}
	else if (input < 0)
	{
		int output = (this->max * input) / this->maxGas;
		return output;
	}
	else
	{
		return -1;
	}
}
void CPController::calibrate(int min)
{

}
